namespace CSharpPro._0923;

public class Work1
{
   public void Test1()
   {
      double price0 = 8800;
      double price1 = 0;
      Console.WriteLine("请选择您要出行的月份（1—12）：");
      int month =int.Parse(Console.ReadLine());
      Console.WriteLine("请选择您要出行的方式(航班/动车)：");
      string transport=Console.ReadLine();
      
      if (month >= 5 && month <= 10)
      {
            if (transport == "航班")
            {
               price1 = price0 * 0.9;
            }
            else if (transport == "动车")
            {
               price1 = price0 * 0.75;
            }
            else
            {
               Console.WriteLine("交通方式输入错误，请输入“航班”或“动车”！");
               return;
            }
      }
      else
      {
            if (transport == "航班")
            {
               price1 = price0 * 0.6;
            }
            else if (transport == "动车")
            {
               price1 = price0 * 0.3;
            }
            else
            {
               Console.WriteLine("交通方式输入错误，请输入“航班”或“动车”！");
               return;
            }
      }
      Console.WriteLine($"旅游行程的折扣后价格为：{price1} 元");
      }
   }
      
   
